[improve][function] Introduced protections against deserialization attacks#22723
[improve][function] Introduced protections against deserialization attacks#22723aditchawdhary wants to merge 1 commit intoapache:masterfrom
Conversation
|
@Khac Please add the following content to your PR description and select a checkbox: |
|
hey lhotari, Technoboy-, codelipenghui, gaoran10, congbobo184 and liangyepianzhou can you take a look? |
Great contribution! Thanks. |
liangyepianzhou
left a comment
There was a problem hiding this comment.
Thanks for your work! It is a great catch. Leave a little comment.
| </dependencies> | ||
| </dependencyManagement> | ||
| <properties> | ||
| <versions.java-security-toolkit>1.1.3</versions.java-security-toolkit> |
There was a problem hiding this comment.
Please add the properties in the parent pom file.
Motivation
This change hardens Java deserialization operations against attack. Even a simple operation like an object deserialization is an opportunity to yield control of your system to an attacker. In fact, without specific, non-default protections, any object deserialization call can lead to arbitrary code execution.
Modifications
I have added pixee java security toolkit as a dependency, and in pulsar functions in the the Serialization/ Deserialization file I have added
ObjectInputFilters.enableObjectFilterIfUnprotectedto the object input stream.Motivation
Modifications
Verifying this change
This change is a trivial rework / code cleanup without any test coverage.
(example:)
Does this pull request potentially affect one of the following parts:
If the box was checked, please highlight the changes
Documentation
docdoc-requireddoc-not-neededdoc-completeMatching PR in forked repository
PR in forked repository: